Skip to content

Conversation

@timotheecour
Copy link
Member

@timotheecour timotheecour commented Mar 9, 2021

this PR replaces backtick by __ (double underscore) in gensym symbols.

rationale:

  • simpler
  • ` is confusing, eg in js it causes this code:
import std/jsconsole
template fn() =
  var x0 = 2
  echo astToStr(x0)
  console.log(x0)
fn()

to escape the backtick via HEX60 which obfuscates the code for no reason:
x0HEX60gensym0_704643076

  • it's hard to backtick X`gensymY (eg in docs etc) because it contains a backtick

  • double underscore is already illegal in nim so there is no risk of accidental conflation

@Araq Araq added the merge_when_passes_CI mergeable once green label Mar 9, 2021
@timotheecour timotheecour force-pushed the pr_gensym_pretty branch 2 times, most recently from c67e428 to cb26ca6 Compare March 10, 2021 23:02
@stale
Copy link

stale bot commented Mar 19, 2022

This pull request has been automatically marked as stale because it has not had recent activity. If you think it is still a valid PR, please rebase it on the latest devel; otherwise it will be closed. Thank you for your contributions.

@stale stale bot added the stale Staled PR/issues; remove the label after fixing them label Mar 19, 2022
@stale stale bot removed the stale Staled PR/issues; remove the label after fixing them label Mar 22, 2022
@ringabout
Copy link
Member

It doesn't work.

@ringabout ringabout closed this Aug 8, 2022
@ringabout ringabout deleted the pr_gensym_pretty branch June 12, 2024 14:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge_when_passes_CI mergeable once green

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants