mapbox / mapbox/shelf-pack-cpp

Default parameters

Open
#12 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

question
Dominant language
C++
Stars
16
Forks
13
PR merge metrics
No merged PRs in 30d

Description

I'm wondering why the parameters for Bin are set to default to -1, in particular for x and y. Would a better default be 0?

/cc @bhousel

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with include/shelf-pack.hpp lines 36-42 and trace how Bin's default x and y values are interpreted. Determine whether -1 is an intentional sentinel or whether 0 matches the surrounding API expectations. Done requires a maintainer-approved decision and an update to the declaration if the default should change.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
tooling
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.