nssalian commented on code in PR #9:
URL: 
https://github.com/apache/iceberg-verification/pull/9#discussion_r4099445446


##########
table-spec/types/README.md:
##########
@@ -0,0 +1,116 @@
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~   http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+  -->
+
+# Type decoding
+
+Parsing a type string produces the same type in every implementation. This
+surface pins each type the spec defines and the parse rules that attach to it.
+
+## Assertion
+
+```
+parse(input) == decoded
+```
+
+`input` is a type string, or a JSON object for a nested type; `decoded` is the
+language-neutral shape below. Bytes are not compared - each implementation maps
+its own type object to `decoded`, so the comparison does not depend on one
+language's representation.
+
+- `valid: true` - the parser succeeds and the decoded type equals `decoded`. A
+  type an implementation does not model is UNSUPPORTED, not a failure. If the 
case
+  also carries `canonical`, re-serializing the parsed type must equal it byte 
for
+  byte (the write direction).
+- `valid: false` - the parser must reject `input`. A rejection passes; a
+  successful parse fails.
+
+`canonical` is present only where the spec pins one spelling. `decimal` has two
+blessed forms (`decimal(9,2)` and `decimal(9, 2)`), so its cases have no

Review Comment:
   [#18145](https://github.com/apache/iceberg/pull/18145) has now aligned the 
decimal type string to the spaced `decimal(<P>, <S>)`. Pinned `canonical: 
"decimal(9, 2)"` on `decimal-9-2` and `decimal-9-2-spaced`; README updated so 
the spaced form is canonical and the no-space `decimal(9,2)` is the 
reader-accept input. 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to