Closed charJe closed 3 years ago
The inclusion of the boolean options commit makes me realize I haven't pushed out my changes that include schema support. The lack of those options is intentional, as this is an implementation of YAML 1.3; the YAML 1.2 schema is on my hard drive; I'll get it cleaned up and pushed tonight. Can you remake the PR without 3479ba5?
There you go. I don't understand things like 1.2 s 1.3. I just realized that Common Lisp didn't have a yaml printer. I really like the way your library is designed by the way.
derp, I meant 1.1 vs 1.2
Anyways this is "good enough to merge" at this point; there's some stylistic changes I'd like to make and also we should be able to stringify vectors, but those can be done easily enough post-merge.
Shouldn't vector being a subclass of array make it work?
@charJe oh, I see that now. I searched for vector not array. That's all good then
Now that I'm thinking about vectors, I realize that I missed printing empty sequence as []
. I can do that if you want.
I can handle the empty-sequence.
Quick question about stringify-documents
why does it not stringify the first item in the list passed to it?
Wouldn't the first element always be the keyword :documents
. If you want, you could move the call to rest
into the stringify cons method.
oh, I see that now.
Another question. I notice that you manually expand newlines on windows. Are there real implementations that don't do that for you automatically? (i.e. where (write-char #\Newline) doesn't output a return/newline sequence)?
😅 I actually don't know about that. I was more or less just playing with read time conditionals; Feel free to remove. I do think it is still good idea to have a variable in case someone wants to customize it though.
I also added the rest of the Boolean options.