Path: csiph.com!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Paul Rubin Newsgroups: comp.lang.forth Subject: Re: Moving JSON around. Date: Sat, 25 Feb 2017 01:50:55 -0800 Organization: A noiseless patient Spider Lines: 15 Message-ID: <87zihak39c.fsf@nightsong.com> References: <9520efbe-f7e6-46b9-a052-7c0b99b0a352@googlegroups.com> <207762ab-6662-4825-a20a-173ff426c521@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: mx02.eternal-september.org; posting-host="7a91307f8fa0a9adcceb343624868e30"; logging-data="22412"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18Tx7HeLzZxCrwydzH60UVk" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) Cancel-Lock: sha1:QeV/CsaN0oeg0vGkWJEdDs8VWqQ= sha1:uqMaIXjDqtXkP+0QaaEvkIUvHX0= Xref: csiph.com comp.lang.forth:55094 Julian Fondren writes: > different tag. Let's say that you push container elements onto a stack If you mean the normal Forth stacks, I don't think that's a usable approach for large Json documents. Some of the packages you tested apparently tried that, and got stack overflows. > In the similar manner you might maintain a type for the entire tree. > Although the only benefit of whole-tree typing that comes to mind is > working with 2d arrays of numbers There's a scheme (no pun intended) out there for supplying XML-like schemas to Json documents. I think I saw something about it on rapidjson.org. That would allow assigning types to the whole tree, individual records in the tree, etc.