Home GnuPG

Make inline remarkup rules have explicit priority
dbbda011392bUnpublished

Unpublished Commit ยท Learn More

Repository Importing: This repository is still importing.

Description

Make inline remarkup rules have explicit priority

Summary:
Currently, inline remarkup rules have implicit priorities (based on the order they're added in). Priority is important; some rules need to apply before other rules.

We just kind of always add them in the right order currently, but this is error prone and creates a concrete problem in Phabricator, where we want applications to be able to add rules with both higher and lower priorities than the hyperlink rule (e.g., "http://example.com/D123" should not link as "D123", so the object rule should run later -- but "https://app.asana.com/..." should link as an Asana object, so the Asana rule should run earlier).

Allow rules to have explicit priorities so the order they're added in doesn't matter.

Test Plan: This just makes the current implicit order explicit. Ran unit tests.

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Differential Revision: https://secure.phabricator.com/D6329

Details

Provenance
epriestley <git@epriestley.com>Authored on Jul 1 2013, 9:27 PM
Parents
rPHUTIL15879abc4919: Shut down active write guard on exit
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPHUTILdbbda011392b: Make inline remarkup rules have explicit priority (authored by epriestley <git@epriestley.com>).Jul 1 2013, 9:27 PM