GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Filled array displayed like [] in debug repl · Issue #6444 · nodejs/node

Filled array displayed like [] in debug repl #6444

New issue
Copy link
New issue
Copy link
Closed
Closed
Filled array displayed like [] in debug repl#6444
Copy link
Labels
v8 engineIssues and PRs related to the V8 dependency.

Description

@evegreen
evegreen
opened on Apr 28, 2016
Issue body actions
  • Version: 6.0.0
  • Platform:
  • Linux ... 3.16.0-70-generic Proposal: Harmony enabled binary, packages. #90~14.04.1-Ubuntu SMP Wed Apr 6 22:56:34 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
  • Windows 7 Ultimate x64

Steps:

  • create file with this content:
debugger;
  • in console: node debug fileName.js (enter)
  • when stops at breakpoint, enable repl
  • type this: myVar = [{lol: 'lal'}]; (enter)
  • type: myVar (enter)

Expected:
[ { lol: 'lal' } ]

Actual:
[]

PS:

  • if i start simple repl (not debug), this bug don't reproduce
  • i can't reproduce this bug on v5.3.0 on windows 10
  • sorry for my "bad" english

Activity

  1. addaleax
    added
    debugger
    on Apr 28, 2016
  2. addaleax commented on Apr 28, 2016

    @addaleax
    addaleax
    on Apr 28, 2016
    Member
    More actions

    Bisecting says this was introduced somewhere in 069e02a, 89f2343, 079973b from #4722.

    /cc @nodejs/v8

  3. addaleax
    added
    v8 engineIssues and PRs related to the V8 dependency.
    on Apr 28, 2016
  4. cjihrig commented on Apr 28, 2016

    @cjihrig
    cjihrig
    on Apr 28, 2016
    Contributor
    More actions

    It looks like something subtly changed from a number to a string. cjihrig@b64463f appears to fix the problem, but I'm unsure if it is the "correct" fix or not.

  5. addaleax commented on Apr 28, 2016

    @addaleax
    addaleax
    on Apr 28, 2016
    Member
    More actions

    @cjihrig This may be a dumb question, but, like… is there any reason not to just do what the comment says? i.e. check for prop.name === 'length'? Good catch anyway!

    That code has been around since 0fa3f2f and I think changing it to that would be correct here anyway.

    // debug repl, node v5.11
    > a = [1]; a.b = 2; a
    [ 1 ]
    // normal repl
    > a = [1]; a.b = 2; a
    [ 1, b: 2 ]

    I’d expect these to match.

  6. cjihrig commented on Apr 28, 2016

    @cjihrig
    cjihrig
    on Apr 28, 2016
    Contributor
    More actions

    Good question. It certainly seems like that would be fine, but there could be some historical context that I don't know about. I can put together a PR and see what people say :-)

  7. addaleax commented on Apr 28, 2016

    @addaleax
    addaleax
    on Apr 28, 2016
    Member
    More actions

    @cjihrig … if you don’t I will. 😄

  8. evegreen commented on Apr 29, 2016

    @evegreen
    evegreen
    on Apr 29, 2016
    Author
    More actions

    Thank you very much! =)

  9. cjihrig
    added a commit that references this issue on May 2, 2016

    debugger: display array contents in repl

    d2eb935
  10. cjihrig
    closed this as completedin #6448on May 2, 2016
  11. Fishrock123
    added a commit that references this issue on May 4, 2016

    debugger: display array contents in repl

    2d503b1
  12. joelostrowski
    added a commit that references this issue on May 4, 2016

    debugger: display array contents in repl

    3315018
  13. MylesBorins
    added a commit that references this issue on Jun 2, 2016

    debugger: display array contents in repl

    d11d559
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    v8 engineIssues and PRs related to the V8 dependency.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402775 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.