Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • C curry-frontend
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 71
    • Issues 71
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 8
    • Merge requests 8
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • curry
  • curry-frontend
  • Issues
  • #101

Closed
Open
Created Nov 19, 2020 by Finn Teegen@fteMaintainer

Deriving fails for empty data types

When trying to compile a program like

data A

the compiler fails with the following error message.

pakcs-frontend: Prelude.head: empty list

This is most likely due to the current way of generating the equations for binary operations (in this case the generation of the equations of the Data class; for all other classes the DeriveCheck should throw an error that classes can't be derived for abstract data types). The obvious solution would be to add an additional check in the DeriveTransformation (see hasDataInstance) to rule out abstract data types.

Edited Nov 19, 2020 by Finn Teegen
Assignee
Assign to
Time tracking