Skip to content

Commit 71d31db

Browse files
committed
Bump to v1.4.0
1 parent e8f784e commit 71d31db

File tree

23 files changed

+57
-26
lines changed

23 files changed

+57
-26
lines changed

.github/workflows/main.yml

+10-2
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,11 @@ jobs:
6161
strategy:
6262
fail-fast: false
6363
matrix:
64-
os: [ubuntu-latest, ubuntu-24.04-arm, macos-latest, windows-latest]
64+
os:
65+
- ubuntu-latest
66+
- ubuntu-24.04-arm
67+
- macos-latest
68+
# - windows-latest <-- failing with fiddle error, temporarily disabled
6569
runs-on: ${{ matrix.os }}
6670
steps:
6771
- uses: actions/checkout@v4
@@ -116,7 +120,11 @@ jobs:
116120
strategy:
117121
fail-fast: false
118122
matrix:
119-
os: [ubuntu-latest, ubuntu-24.04-arm, macos-latest, windows-latest]
123+
os:
124+
- ubuntu-latest
125+
- ubuntu-24.04-arm
126+
- macos-latest
127+
# - windows-latest <-- failing with fiddle error, temporarily disabled
120128
runs-on: ${{ matrix.os }}
121129
steps:
122130
- uses: actions/checkout@v4

CHANGELOG.md

+24-1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,28 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) a
66

77
## [Unreleased]
88

9+
## [1.4.0] - 2025-03-18
10+
11+
### Added
12+
13+
- Support `3.5` as a version option.
14+
- Many, many compatibility fixes for the parser translation layer.
15+
- Handle escapes in named capture names.
16+
- The `freeze` option is added to the various `Prism::` APIs to deeply freeze the AST.
17+
- Properly support `it` for the parser and ruby_parser translation layers.
18+
- Track the `then` keyword on `rescue` nodes.
19+
- Add a `multiple_statements?` flag to parentheses nodes to support desired `defined?` behavior.
20+
21+
### Changed
22+
23+
- The strings used in the AST are now frozen.
24+
- Fixed handling escaped characters after control sequences in character literals.
25+
- Fix reading off the end of an unterminated global variable.
26+
- Raise a syntax error for defining `[]=` with endless method syntax.
27+
- Increase value of `PRISM_DEPTH_MAXIMUM` to `10000`.
28+
- Freeze `Prism::VERSION`.
29+
- Fix up rescue modifier precedence.
30+
931
## [1.3.0] - 2024-12-21
1032

1133
### Added
@@ -627,7 +649,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) a
627649

628650
- 🎉 Initial release! 🎉
629651

630-
[unreleased]: https://github.com/ruby/prism/compare/v1.3.0...HEAD
652+
[unreleased]: https://github.com/ruby/prism/compare/v1.4.0...HEAD
653+
[1.4.0]: https://github.com/ruby/prism/compare/v1.3.0...v1.4.0
631654
[1.3.0]: https://github.com/ruby/prism/compare/v1.2.0...v1.3.0
632655
[1.2.0]: https://github.com/ruby/prism/compare/v1.1.0...v1.2.0
633656
[1.1.0]: https://github.com/ruby/prism/compare/v1.0.0...v1.1.0

Gemfile.lock

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: .
33
specs:
4-
prism (1.3.0)
4+
prism (1.4.0)
55

66
GEM
77
remote: https://rubygems.org/

docs/releasing.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ ruby -pi -e 'gsub(/^ruby-prism-sys = \{ version = ".+?"/, %Q{ruby-prism-sys = \{
4040
* Update the `Gemfile.lock` file:
4141

4242
```sh
43-
chruby ruby-3.4.0-dev
43+
chruby ruby-3.5.0-dev
4444
bundle install
4545
```
4646

ext/prism/extension.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#ifndef PRISM_EXT_NODE_H
22
#define PRISM_EXT_NODE_H
33

4-
#define EXPECTED_PRISM_VERSION "1.3.0"
4+
#define EXPECTED_PRISM_VERSION "1.4.0"
55

66
#include <ruby.h>
77
#include <ruby/encoding.h>

gemfiles/2.7/Gemfile.lock

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: ../..
33
specs:
4-
prism (1.3.0)
4+
prism (1.4.0)
55

66
GEM
77
remote: https://rubygems.org/

gemfiles/3.0/Gemfile.lock

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: ../..
33
specs:
4-
prism (1.3.0)
4+
prism (1.4.0)
55

66
GEM
77
remote: https://rubygems.org/

gemfiles/3.1/Gemfile.lock

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: ../..
33
specs:
4-
prism (1.3.0)
4+
prism (1.4.0)
55

66
GEM
77
remote: https://rubygems.org/

gemfiles/3.2/Gemfile.lock

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: ../..
33
specs:
4-
prism (1.3.0)
4+
prism (1.4.0)
55

66
GEM
77
remote: https://rubygems.org/

gemfiles/3.3/Gemfile.lock

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: ../..
33
specs:
4-
prism (1.3.0)
4+
prism (1.4.0)
55

66
GEM
77
remote: https://rubygems.org/

gemfiles/3.4/Gemfile.lock

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: ../..
33
specs:
4-
prism (1.3.0)
4+
prism (1.4.0)
55

66
GEM
77
remote: https://rubygems.org/

gemfiles/3.5/Gemfile.lock

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: ../..
33
specs:
4-
prism (1.3.0)
4+
prism (1.4.0)
55

66
GEM
77
remote: https://rubygems.org/

gemfiles/jruby/Gemfile.lock

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: ../..
33
specs:
4-
prism (1.3.0)
4+
prism (1.4.0)
55

66
GEM
77
remote: https://rubygems.org/

gemfiles/truffleruby/Gemfile.lock

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
PATH
22
remote: ../..
33
specs:
4-
prism (1.3.0)
4+
prism (1.4.0)
55

66
GEM
77
remote: https://rubygems.org/

include/prism/version.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
/**
1515
* The minor version of the Prism library as an int.
1616
*/
17-
#define PRISM_VERSION_MINOR 3
17+
#define PRISM_VERSION_MINOR 4
1818

1919
/**
2020
* The patch version of the Prism library as an int.
@@ -24,6 +24,6 @@
2424
/**
2525
* The version of the Prism library as a constant string.
2626
*/
27-
#define PRISM_VERSION "1.3.0"
27+
#define PRISM_VERSION "1.4.0"
2828

2929
#endif

javascript/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@ruby/prism",
3-
"version": "1.3.0",
3+
"version": "1.4.0",
44
"description": "Prism Ruby parser",
55
"type": "module",
66
"main": "src/index.js",

prism.gemspec

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Gem::Specification.new do |spec|
44
spec.name = "prism"
5-
spec.version = "1.3.0"
5+
spec.version = "1.4.0"
66
spec.authors = ["Shopify"]
77
spec.email = ["[email protected]"]
88

rust/ruby-prism-sys/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "ruby-prism-sys"
3-
version = "1.3.0"
3+
version = "1.4.0"
44
edition = "2021"
55
license-file = "../../LICENSE.md"
66
repository = "https://github.com/ruby/prism"

rust/ruby-prism-sys/tests/utils_tests.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ fn version_test() {
1212
CStr::from_ptr(version)
1313
};
1414

15-
assert_eq!(&cstring.to_string_lossy(), "1.3.0");
15+
assert_eq!(&cstring.to_string_lossy(), "1.4.0");
1616
}
1717

1818
#[test]

rust/ruby-prism/Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "ruby-prism"
3-
version = "1.3.0"
3+
version = "1.4.0"
44
edition = "2021"
55
license-file = "../../LICENSE.md"
66
repository = "https://github.com/ruby/prism"
@@ -26,7 +26,7 @@ serde = { version = "1.0", features = ["derive"] }
2626
serde_yaml = "0.9"
2727

2828
[dependencies]
29-
ruby-prism-sys = { version = "1.3.0", path = "../ruby-prism-sys" }
29+
ruby-prism-sys = { version = "1.4.0", path = "../ruby-prism-sys" }
3030

3131
[features]
3232
default = ["vendored"]

templates/java/org/prism/Loader.java.erb

+1-1
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ public class Loader {
101101
expect((byte) 'M', "incorrect prism header");
102102

103103
expect((byte) 1, "prism major version does not match");
104-
expect((byte) 3, "prism minor version does not match");
104+
expect((byte) 4, "prism minor version does not match");
105105
expect((byte) 0, "prism patch version does not match");
106106

107107
expect((byte) 1, "Loader.java requires no location fields in the serialized output");

templates/javascript/src/deserialize.js.erb

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import * as nodes from "./nodes.js";
22

33
const MAJOR_VERSION = 1;
4-
const MINOR_VERSION = 3;
4+
const MINOR_VERSION = 4;
55
const PATCH_VERSION = 0;
66

77
// The DataView getFloat64 function takes an optional second argument that

templates/lib/prism/serialize.rb.erb

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ module Prism
1010

1111
# The minor version of prism that we are expecting to find in the serialized
1212
# strings.
13-
MINOR_VERSION = 3
13+
MINOR_VERSION = 4
1414

1515
# The patch version of prism that we are expecting to find in the serialized
1616
# strings.

0 commit comments

Comments
 (0)