GithubHelp home page GithubHelp logo

refact's Introduction

refact's People

Contributors

mpickering avatar alexfmpe avatar

Stargazers

Hécate Moonlight avatar Tristan de Cacqueray avatar Tim Kersey avatar Ilmari Vacklin avatar  avatar Eric Bailey avatar clojj avatar Bryan Garza avatar Daniel Kahlenberg avatar

Watchers

Alan Zimmerman avatar James Cloos avatar  avatar  avatar  avatar

refact's Issues

Think about making SrcSpan more efficient

The current definition of SrcSpan takes a lot of memory and is quite prone to space leaks. I would expect to see:

data SrcSpan = SrcSpan {startCol :: {-# UNPACK #-} !Int, startLine :: {-# UNPACK #-} !Int, ...}

That definition takes 32 bytes on a 64bit machine and has no space leaks. In contrast, your definition will be more like 80 bytes and highly likely to space leak if someone isn't careful. Perhaps think about switching. In practice, it might not be a bottleneck, and thus might be not so bad.

Add more derivations

Add Data/Typeable to the definitions without exception - they are very handy for SYB style stuff (which HLint does a lot of).

If RType will always be an enum (as it looks plausible) think about also adding Enum and Bounded, which gives you the handy [minBound..maxBound] to loop over all RTypes, but that one is less important, and arguably there's little chance to by polymorphic over the RType, so it might not make sense.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.