Re: Unexpected "#_ - Discard" error

2021-04-03 Thread Laurens Van Houtven
On Sat, Apr 3, 2021 at 08:50 zen...@gmail.com  wrote:

> I'm reading https://clojure.org/guides/weird_characters#_discard and run
> into this error:
>
> *user> #_({1:2})*
>
> *Syntax error reading source at (REPL:247:14).*
> *Invalid number: 1:2*
>

#_ is a reader macro—so what’s inside still has to be syntactically valid
(to the reader).

When trying to parse the literal, presumably because it ends and/or starts
with a digit, it is incorrectly interpreted as a number. It’s presumably
missing a space depending on what you intended that literal to mean.

lvh


Ty.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clojure@googlegroups.com
> Note that posts from new members are moderated - please be patient with
> your first post.
> To unsubscribe from this group, send email to
> clojure+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "Clojure" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to clojure+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/clojure/4d306d9a-c030-4387-b92d-8e6fb2d5b63an%40googlegroups.com
> 
> .
>
-- 
Sent from Gmail Mobile

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/clojure/CAE_Hg6YxV7jXN9HL4Qf%3DsjkupT1%3DMZ53MQktArJNW9jAR9eTVg%40mail.gmail.com.


Re: Unexpected "#_ - Discard" error

2021-04-03 Thread zen...@gmail.com
 Thank you for the clarification. I'll use ';' instead.

* The docs suggest that "The form following #_ is completely skipped by the 
reader (This is a more complete removal than the comment macro which yields 
nil).". This can prove useful for debugging situations or for multiline 
comments. *


On Saturday, April 3, 2021 at 10:46:42 AM UTC-4 Alex Miller wrote:

> The discard reader will read, then discard (so the following form still 
> has to be readable). In this case, the 1:2 starts with a number so is 
> parsed as one, but that's an invalid form.
>
>
> On Saturday, April 3, 2021 at 8:50:49 AM UTC-5 zen...@gmail.com wrote:
>
>> I'm reading https://clojure.org/guides/weird_characters#_discard and run 
>> into this error:
>>
>> *user> #_({1:2})*
>>
>> *Syntax error reading source at (REPL:247:14).*
>> *Invalid number: 1:2*
>>
>> Ty.
>>
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/clojure/8a659371-db87-4974-a82d-4f35392e56dbn%40googlegroups.com.


Re: Unexpected "#_ - Discard" error

2021-04-03 Thread zen...@gmail.com
Thank you for the clarification. I save a 'curl' usage for posting json to 
a separate text file versus in .clj for now.

* The docs suggest that "The form following #_ is completely skipped by the 
reader (This is a more complete removal than the comment macro which yields 
nil).". This can prove useful for debugging situations or for multiline 
comments. *

On Saturday, April 3, 2021 at 10:46:42 AM UTC-4 Alex Miller wrote:

> The discard reader will read, then discard (so the following form still 
> has to be readable). In this case, the 1:2 starts with a number so is 
> parsed as one, but that's an invalid form.
>
>
> On Saturday, April 3, 2021 at 8:50:49 AM UTC-5 zen...@gmail.com wrote:
>
>> I'm reading https://clojure.org/guides/weird_characters#_discard and run 
>> into this error:
>>
>> *user> #_({1:2})*
>>
>> *Syntax error reading source at (REPL:247:14).*
>> *Invalid number: 1:2*
>>
>> Ty.
>>
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/clojure/0bc06793-dc7c-4437-a3eb-41439fcb5e66n%40googlegroups.com.


Re: Unexpected "#_ - Discard" error

2021-04-03 Thread Alex Miller
The discard reader will read, then discard (so the following form still has 
to be readable). In this case, the 1:2 starts with a number so is parsed as 
one, but that's an invalid form.


On Saturday, April 3, 2021 at 8:50:49 AM UTC-5 zen...@gmail.com wrote:

> I'm reading https://clojure.org/guides/weird_characters#_discard and run 
> into this error:
>
> *user> #_({1:2})*
>
> *Syntax error reading source at (REPL:247:14).*
> *Invalid number: 1:2*
>
> Ty.
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/clojure/3722ff93-47f7-4084-91e6-ac2d02feafc4n%40googlegroups.com.


Unexpected "#_ - Discard" error

2021-04-03 Thread zen...@gmail.com
I'm reading https://clojure.org/guides/weird_characters#_discard and run 
into this error:

*user> #_({1:2})*

*Syntax error reading source at (REPL:247:14).*
*Invalid number: 1:2*

Ty.

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/clojure/4d306d9a-c030-4387-b92d-8e6fb2d5b63an%40googlegroups.com.