Discussion:
[Bug rust/22545] New: add inclusive range syntax to rust
tromey at sourceware dot org
2017-12-04 17:18:19 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=22545

Bug ID: 22545
Summary: add inclusive range syntax to rust
Product: gdb
Version: HEAD
Status: NEW
Severity: enhancement
Priority: P2
Component: rust
Assignee: unassigned at sourceware dot org
Reporter: tromey at sourceware dot org
Target Milestone: ---

Rust is getting syntax for an inclusive range, see
https://github.com/rust-lang/rust/issues/28237

At some point (I'm generally not sure if this sort of thing should
be done when the feature stabilizes, or earlier), this should
be added to rust-exp.y.
--
You are receiving this mail because:
You are on the CC list for the bug.
tromey at sourceware dot org
2018-03-16 15:36:45 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=22545

--- Comment #1 from Tom Tromey <tromey at sourceware dot org> ---
This has been stabilized now.
--
You are receiving this mail because:
You are on the CC list for the bug.
tromey at sourceware dot org
2018-03-29 19:42:14 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=22545

Tom Tromey <tromey at sourceware dot org> changed:

What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at sourceware dot org |tromey at sourceware dot org

--- Comment #2 from Tom Tromey <tromey at sourceware dot org> ---
Working on this.
--
You are receiving this mail because:
You are on the CC list for the bug.
tromey at sourceware dot org
2018-03-29 20:16:37 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=22545

--- Comment #3 from Tom Tromey <tromey at sourceware dot org> ---
https://sourceware.org/ml/gdb-patches/2018-03/msg00601.html
--
You are receiving this mail because:
You are on the CC list for the bug.
cvs-commit at gcc dot gnu.org
2018-04-27 19:26:25 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=22545

--- Comment #4 from cvs-commit at gcc dot gnu.org <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Tom Tromey <***@sourceware.org>:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=6873858b7e464e114f9a877e216949ad8350b4cf

commit 6873858b7e464e114f9a877e216949ad8350b4cf
Author: Tom Tromey <***@tromey.com>
Date: Thu Mar 29 14:14:07 2018 -0600

Add inclusive range support for Rust

This is version 2 of the patch to add inclusive range support for
Rust. I believe it addresses all review comments.

Rust recently stabilized the inclusive range feature:

https://github.com/rust-lang/rust/issues/28237

An inclusive range is an expression like "..= EXPR" or "EXPR ..=
EXPR". It is like an ordinary range, except the upper bound is
inclusive, not exclusive.

This patch adds support for this feature to gdb.

Regression tested on x86-64 Fedora 27.

2018-04-27 Tom Tromey <***@tromey.com>

PR rust/22545:
* rust-lang.c (rust_inclusive_range_type_p): New function.
(rust_range): Handle inclusive ranges.
(rust_compute_range): Likewise.
* rust-exp.y (struct rust_op) <inclusive>: New field.
(DOTDOTEQ): New constant.
(range_expr): Add "..=" productions.
(operator_tokens): Add "..=" token.
(ast_range): Add "inclusive" parameter.
(convert_ast_to_expression) <case OP_RANGE>: Handle inclusive
ranges.
* parse.c (operator_length_standard) <case OP_RANGE>: Handle new
bounds values.
* expression.h (enum range_type) <NONE_BOUND_DEFAULT_EXCLUSIVE,
LOW_BOUND_DEFAULT_EXCLUSIVE>: New constants.
Update comments.
* expprint.c (print_subexp_standard): Handle new bounds values.
(dump_subexp_body_standard): Likewise.

2018-04-27 Tom Tromey <***@tromey.com>

PR rust/22545:
* gdb.rust/simple.exp: Add inclusive range tests.
--
You are receiving this mail because:
You are on the CC list for the bug.
tromey at sourceware dot org
2018-04-27 20:27:37 UTC
Permalink
https://sourceware.org/bugzilla/show_bug.cgi?id=22545

Tom Tromey <tromey at sourceware dot org> changed:

What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |FIXED
Target Milestone|--- |8.2

--- Comment #5 from Tom Tromey <tromey at sourceware dot org> ---
Fixed.
--
You are receiving this mail because:
You are on the CC list for the bug.
Loading...