Skip to content

Commit f8e731e

Browse files
macmadeclaude
andcommitted
docs: Qualify the round-trip guarantee in the README
The "round-trips byte-for-byte" claim holds through the strict `FITSFile.data`, which re-validates on serialization, and a trailing partial block is zero-padded at parse time — so a file that only loads under lenient options need not reproduce its input bytes. Say "a compliant file" instead of "a parsed file". Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent 4f3bee2 commit f8e731e

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ This library provides a simple interface to read and write FITS files in Swift,
1717
### Status
1818

1919
SwiftFITS supports both **reading and writing**. It parses existing FITS files into their header/data
20-
structure and serializes them back to standards-compliant bytes. A parsed file round-trips
20+
structure and serializes them back to standards-compliant bytes. A compliant file round-trips
2121
byte-for-byte; you can also build new files from scratch, and edit parsed files in place — only the
2222
sections you modify are re-rendered, while every untouched section keeps its original bytes.
2323

@@ -37,8 +37,8 @@ following properties are intentional, not latent surprises:
3737
- **Section layout is geometry-driven**: each header's declared geometry
3838
(`|BITPIX|/8 × GCOUNT × (PCOUNT + ∏ NAXISn)`, with random groups handled) determines exactly how many
3939
data blocks follow, rather than guessing from byte content. Trailing all-blank padding is preserved.
40-
- **`END`** is excluded from a section's `properties` but is retained in the raw bytes, so a parsed file
41-
round-trips byte-for-byte through `FITSFile.data`.
40+
- **`END`** is excluded from a section's `properties` but is retained in the raw bytes, so a compliant
41+
file round-trips byte-for-byte through `FITSFile.data`.
4242
- **Strict vs. lenient**: `.strict` rejects technically-noncompliant input, while `.lenient` (the
4343
default) tolerates common real-world deviations (unknown value types, trailing characters after a
4444
string's closing quote, non-printable header text, data-length mismatches, a missing space after

0 commit comments

Comments
 (0)