Skip to content

Fixed liveness bug for null array units #3642

Merged
martin-henz merged 3 commits intosource-academy:masterfrom
Akshay-2007-1:null-unit-liveness
Mar 9, 2026
Merged

Fixed liveness bug for null array units #3642
martin-henz merged 3 commits intosource-academy:masterfrom
Akshay-2007-1:null-unit-liveness

Conversation

@Oofky
Copy link
Contributor

@Oofky Oofky commented Mar 9, 2026

Description

This PR fixes a small bug we found where null array units sometimes still show the default stroke color despite being dead/unreferenced. It is a very minor fix and follows the same logic as other objects such as regular array units, so it will not break anything.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update
  • Code quality improvements

How to test

Run the following code (or any code where the frame that references an array with a null unit is dead), and observe that the stroke representing the null unit is greyed out when appropriate:

{
    let a = list(2, null, null);
}
const c = 3;

Before:

Recording.2026-03-09.232820.mp4

After:

Recording.2026-03-09.234600.mp4

Checklist

  • I have tested this code

Fixed the issue where null array units sometimes still have the default stroke color, despite being dead
@Akshay-2007-1 Akshay-2007-1 added the minor Less important than important, but more than nice-to-have label Mar 9, 2026
@Akshay-2007-1 Akshay-2007-1 moved this from Todo to In Progress in SA 2627 CP3108 P05: CSE Machine liveness Mar 9, 2026
Copy link
Member

@martin-henz martin-henz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

@martin-henz martin-henz enabled auto-merge (squash) March 9, 2026 22:27
@martin-henz martin-henz merged commit e678e7e into source-academy:master Mar 9, 2026
7 checks passed
@Akshay-2007-1 Akshay-2007-1 deleted the null-unit-liveness branch March 10, 2026 17:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

minor Less important than important, but more than nice-to-have

Development

Successfully merging this pull request may close these issues.

3 participants