Path: csiph.com!eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail From: Anton Shepelev Newsgroups: comp.lang.javascript Subject: Re: input/output parameters Date: Sat, 10 Apr 2021 14:54:43 +0300 Organization: A noiseless patient Spider Lines: 18 Message-ID: <20210410145443.bb0f41da9704506ada43c158@gmail.com> References: <20210313153232.40fa0c8b0adf07d7e807084d@gmail.com> <20210315002732.dbb3221feb6d3a0c065292cf@gmail.com> <20210320145630.62e1c4dde277c68dcd052e3e@gmail.com> <20210321151659.57d54d5ac979fca6d77b0ba7@gmail.com> <6ea17aef-1a1a-4806-be70-edb109f3d2a2n@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Injection-Info: reader02.eternal-september.org; posting-host="64ef96fa8bec6bbab7a6e3e91c8d19a8"; logging-data="28443"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/cszQ8xu1OvuKesjUSeD2+THgnAHZ5tqE=" Cancel-Lock: sha1:rkj1oJoJzQSLI6xhwoUdmbJeUqQ= X-Newsreader: Sylpheed 3.7.0 (GTK+ 2.24.30; i686-pc-mingw32) Xref: csiph.com comp.lang.javascript:39882 Michael Haufe: > Talk of a "pure" annotation comes up from time to time in > the design committee but practically part of the debate > is: why annotate if you can identify purity with program > analysis? Program analysis is desirable in either case, at least to make sure that the programmer does not misinform the reader and compiler by marking an impure function as pure. My point is that pieces of "pure" eval() code (including non-strict mode) can be considered compile-time macros. I still feel a cognitive dissonance, however, every time a compiler is mentioned for a language named JavaScript... -- () ascii ribbon campaign -- against html e-mail /\ http://preview.tinyurl.com/qcy6mjc [archived]