Improved type system
This commit is contained in:
parent
8eabcf258d
commit
69a5fdc703
20 changed files with 111 additions and 67 deletions
6
src/types/Check.go
Normal file
6
src/types/Check.go
Normal file
|
@ -0,0 +1,6 @@
|
|||
package types
|
||||
|
||||
// Check returns true if the first type can be converted into the second type.
|
||||
func Check(a *Type, b *Type) bool {
|
||||
return a == nil || a == b
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue