Skip to content

Commit

Permalink
3.5.0 Detect namespace from in-ns forms
Browse files Browse the repository at this point in the history
  • Loading branch information
tonsky committed Jan 22, 2024
1 parent 7e91822 commit 24c1172
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
### 3.5.0 - Jan 22, 2023

- Detect namespace from in-ns forms

### 3.4.1 - Dec 7, 2023

- Fixed status eval not clearing on disconnect
Expand Down
7 changes: 7 additions & 0 deletions cs_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -438,6 +438,13 @@ def namespace(view, point):
second_form = second_form.body.children[0]
if is_symbol(second_form):
ns = second_form.text
elif first_form.name == 'token' and first_form.text == 'in-ns':
second_form = body.children[1]
print(second_form.name, second_form.marker.text)
if second_form.name == 'wrap' and second_form.marker.text == "'":
unwrapped = second_form.body.children[0]
if is_symbol(unwrapped):
ns = unwrapped.text
return ns

def plugin_unloaded():
Expand Down

0 comments on commit 24c1172

Please sign in to comment.