I've written a hash-table for an sml assignment. I've made a polymorphic builder for the hashtable but when I use the insert function I created, I get a comparable type (''a instead of 'a) although i'm not making any comparisons that include the type. Does anyone maybe has an idea why? I'm sorry if my code is a bit messy i've highlighted the important parts, the rest are just helper functions.
getting ''a type instead of 'a in sml
126 Views Asked by Shalev rissin At
1
There are 1 best solutions below
Related Questions in POLYMORPHISM
- System.InvalidCastException while inheriting a class
- CRTP Member Visibility
- Custom class fmt::formatter for non const argument
- How to properly inherit from dataclass with base instance re-usage
- Pass class type that subclass or implements class; then access static methods & create instances of that type; is it possible in Java, and how?
- Polymorphism React/typescript : how to tell typescipt that the caller of a component with generic children do not need to specify the child props
- Most pragmatic way to model a type hierarchy in TypeScript
- Traversing a linked list of polymorphic derived type in both directions
- Hide generic type arguments behind concrete type results in CS0535
- How would you create a list/array containing variables instantiated from classes in C#?
- How to make a Template Function in C
- Enum of classes with polymorphism
- Base class method not called on object of derived type: polymorphism without pointer and reference
- Can you use C++ concepts in the same way as polymorphic interfaces?
- Polymorphic many-to-many relationship model property doesn't return collection but ->get() does
Related Questions in SML
- Creating an instance of a Binary Tree (Programming Standard ML by Robert Harper)
- Obtain a function as tree in SML
- TextIO.openIn:"No such file or directory" in Poly/ML
- How to implement Label/TextVIew with giraffe library in SML
- Compiling Giraffe library Hello World on Ubuntu
- How to match function type in signature in SML
- Error "no *.cm, *.mlb, or millet.toml files found in this directory" in VS code using SML
- I'm new to SML/NJ and there's some questions bothering me. I don't know how to use Math or String in the basis lib
- SML Looping through 2 Random variables and ordering them?
- How do I fix my standard ml code when I have an unbound value 'a'?
- How to install and run SML/ NJ in VScode
- UTF-8, Unicode in SML/NJ
- What is the difference between ('a,'b) and ('a*'b)?
- sml standard pop function vs user defiend. And return values
- Error: unbound type constructor: TypeInteger
Related Questions in BUILDER
- Builder pattern with a Java 8 Stream
- Firefox Addon Builder Alternative
- Building fluent APIs in Java to build testdata for database
- How to exclude property from Lombok builder?
- When to use builder design pattern
- How to use builder and stub in WPF C#
- JPA Criteria API in with two lists
- How to clone old builder to make a new builder object?
- Cosmos not showing up for me
- Multiple entries with same key immutable map error
- How to subclass a Java builder class?
- Unable to subclass with Builder pattern: Shipment(Builder) is not public in Shipment; cannot be accessed from outside package
- Java ,GUI window builder
- Builder Pattern: What is the purpose of the Director?
- Linux gitian-builder and "dpkg: error processing package sudo"
Related Questions in METALANGUAGE
- What's the different between these two `type` define which have different generic place, and how to use them?
- getting ''a type instead of 'a in sml
- Understanding "let" & "in" in ML programming
- Creating A Dictionary In SML
- Is there a metalanguage, similar to BNF that can concisely describe self-describing data?
- Understanding terminology used to describe the DOM
- Why is ML called Meta-Language?
- How do I put the code `cons[A;B]` in a repl, run it, and see the output `(A . B)`?
- Is there a complete metalanguage?
- Fragment function seems properly written but Metal complains
- MTLPixelFormatInvalid in XCode8 Swift 2.2
- OSX - Convert GLSL 'InOut' to Metal
- Module meta-language in Racket
- Standard Meta Language: are hd and tl evaluated right or left first?
- Silhouette Outline Shader Modifier via Metal in SceneKit
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?

the solution is using a switch case instead of "if" comparisons, that way the compiler can get mixed up and assume a type needs to be comparable although it does not.