Skip to content

Commit

Permalink
Fix(?) f-string formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
CFiggers committed Sep 12, 2023
1 parent cc97e60 commit 8be3229
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 7 deletions.
17 changes: 17 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
# Change Log

## 0.0.8 (Sep 12, 2023)
- Fixed broken f-string reformatting

## 0.0.7 (Sep 10, 2023)
- f-strings now syntax highlight interpolated sections as regular Hy code
- Added missing keywords and function names from syntax highlighting

## 0.0.6 (Sep 4, 2023)
- Improved command and shortcut availability (more commands hidden when not relevant)
- Updated command namespacing to avoid conflicts with similar extensions

## 0.0.5 (Sep 2, 2023)
- Introduced webpack

## 0.0.4 (Jul 31, 2023)
- Bugfixes with autoformatting (indentation, comma handling, auto comment continuation)

## 0.0.3 (Dec 20, 2022)
- Added ParEdit-style structural editing
- Added format-on-type (incl. auto-indentation)
Expand Down
2 changes: 1 addition & 1 deletion dist/extension.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/extension.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"hy",
"syntax"
],
"version": "0.0.7",
"version": "0.0.8",
"publisher": "hylang",
"icon": "images/hy-logo-small.png",
"main": "./dist/extension.js",
Expand Down
8 changes: 5 additions & 3 deletions src/cljs-lib/src/pez_rewrite_clj/parser/core.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,11 @@

(defn parse-charf
[^not-native reader]
(case (peek-char reader)
\" (parse-fstring reader)
(parse-token reader)))
(reader/ignore reader)
(if (= (peek-char reader) \")
(parse-fstring reader)
(do (reader/unread reader \f)
(parse-token reader))))


(defn- parse-unmatched
Expand Down
2 changes: 1 addition & 1 deletion src/cljs-lib/src/pez_rewrite_clj/reader.cljs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
(ns pez-rewrite-clj.reader
(:refer-clojure :exclude [peek next])
(:require [cdf-rewrite-cljs-reader.reader :as r]
(:require [cljs.tools.reader :as r]
[cljs.tools.reader.reader-types :as reader-types]
[cljs.tools.reader.impl.commons :refer [parse-symbol]]
[goog.string :as gstring]
Expand Down

0 comments on commit 8be3229

Please sign in to comment.