visualizing type error messages
Download
Skip this Video
Download Presentation
Visualizing Type Error Messages

Loading in 2 Seconds...

play fullscreen
1 / 14

Visualizing Type Error Messages - PowerPoint PPT Presentation


  • 105 Views
  • Uploaded on

Visualizing Type Error Messages. Allison Thompson CSCI 5535 Spring 2010. Motivation. This expression has type int but is here used with type float. This expression has type my_type but is here used with type my_type. Outline. Motivation Tools: Processing and S eminal ViSeR

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about ' Visualizing Type Error Messages' - deana


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
visualizing type error messages

Visualizing Type Error Messages

Allison Thompson

CSCI 5535 Spring 2010

motivation
Motivation

This expression has type int but is here used with type float

This expression has type my_type but is here used with type my_type

outline
Outline
  • Motivation
  • Tools: Processing and Seminal
  • ViSeR
  • Conclusion
outline1
Outline
  • Motivation
  • Tools: Processing and Seminal
  • ViSeR
  • Conclusion
pros and cons of processing
Pros and Cons of Processing
  • Easy
  • Didn’t require learning new language
  • Free
  • Based on Java 1.4.2 (limited)
  • Does not always run very fast
    • Visualization can take 4-5 sec to load; then 4-5 for each refresh
s eminal s earching for e rror m essages in a dvanced l anguages
Seminal: Searching for Error Messages INAdvanced Languages
  • Enumerate local changes to abstract syntax tree that may remove type errors
  • Search for places to try changes
  • Use type checker to evaluate changes
  • Rank changes and present to user
seminal results
Seminal Results:

1 + 2.5;;

------------------------------------------------------------------

File "test1.ml", line 1, characters 4-7:

This expression has type float but is here used with type int

Relevant code: 2.5

------------------------------------------------------------------

File "test1.ml", line 1, characters 4-7:

Try replacing

2.5

with

2.5; [[...]]

of type

int

within context

1 + (2.5; [[...]]);;

==============================

File "test1.ml", line 1, characters 2-3:

Try replacing

+

with

+; [[...]]

of type

int -> float -> \'a

within context

(1 +; [[...]] 2.5);;

==============================

File "test1.ml", line 1, characters 4-7:

Try replacing

2.5

with

2.5; [[...]]

of type

int

within context

1 + (2.5; [[...]]);;

wildcard replacement with type int

outline2
Outline
  • Motivation
  • Tools: Processing and Seminal
  • ViSeR
  • Conclusion
viser vi sualization for se minal r esults
ViSeR: Visualization for Seminal Results
  • Goals:
    • Put Seminal suggestions in context with some form of helpful visualization
    • Minimize need for user to learn new symbols/etc – improve usability and understandability
    • Avoid re-introducing confusion:

This expression has type int but is here used with type float

viser examples and screenshots
ViSeR: Examples and Screenshots

1 + 2.5;;

File "test1.ml", line 1, characters 4-7:

Try replacing

2.5

with

2.5; [[...]]

of type

int

within context

1 + (2.5; [[...]]);;

wildcard replacement with type int

This expression has type int but is here used with type float

viser examples and screenshots1
ViSeR: Examples and Screenshots

actual error

error location

according

to OCaml

This expression has type int but is here used with type float

outline3
Outline
  • Motivation
  • Tools: Seminal and Processing
  • ViSeR
  • Conclusion
conclusion
Conclusion
  • Success?
    • Put Seminal results in context
    • Provide improvement in usability
  • Remaining Issues/Future Work
    • ViSeR as a tool is limited/slow
      • Several situations doesn’t cover; doesn’t gracefully handle proper compilation
      • 4-5 seconds for some visualizations is too slow

ad