types
What does "A type cannot be be used as a standalone statement" error mean?
This is Delphi Prism for .NET. I am running into this error(s), \"A type cannot be be used as a standalone statement\", and I don\'t understand or know why. The compiler is pointing at the lines right[详细]
2023-04-10 16:58 分类:问答Vowel datatype in Haskell, is it possible?
I have written the following code to remove vowels from a sentence: main = print $ unixname \"The House\"[详细]
2023-04-10 15:36 分类:问答scala reflection, cast type with asInstanceOf
I have trait T class C extends T compiled to .class files. Run scala with -cp <...> to have type T available. Then load class C using reflection:[详细]
2023-04-10 15:11 分类:问答Matrix constructor and method in Haskell
So here is a nested list [[1, 2], [3, 4]] I want to wrap it in a type called Matrix, and make it an instance of the classes Eq, Num, and Show[详细]
2023-04-10 13:18 分类:问答type declarations in 'where' -- what's going on?
While reading the QuickCheck Manual, I came across the following example: prop_RevRev xs = reverse (reverse xs) == xs[详细]
2023-04-10 12:52 分类:问答Detecting if a class/type is defined prior to compiling
This is similar to a few other threads i have found, but I haven\'t found the answer I need yet. I would appreciate a direct answer, even if it is \"no, you can\'t do that\".[详细]
2023-04-10 12:38 分类:问答Haskell - declare/use data
It\'s my first time to use data types in Haskell. Got a problem and I don\'t know how to improve the code.[详细]
2023-04-10 12:30 分类:问答Passing type information to function in Scala
I have code that does some common operation on json objects, namely extract. So what I would like to create generic function that takes type parameter which class to expect, code looks like as follows[详细]
2023-04-10 11:22 分类:问答Couldn't match expected type - Haskell
I\'m new to Haskell and still can\'t quite figure out these type issues.I\'m getting e开发者_高级运维rrors for the following function:[详细]
2023-04-10 04:30 分类:问答Built-in (or popular 3rd party library) way to map between primitive and corresponding reference type ("wrapper")?
I\'m looking for a bidirectional map that, for example, produces java.lang.Boolean.class when a lookup is done on java.lang.Boolean.TYPE, and visa versa. Basically, a primitive ⇆ wrapper map.[详细]
2023-04-10 01:45 分类:问答