# Disambiguating footnotes with back-references

**URL:** https://discourse.citationstyles.org/t/disambiguating-footnotes-with-back-references/1799
**Category:** CSL Development
**Created:** [March 5, 2023, 4:00am UTC](https://discourse.citationstyles.org/t/disambiguating-footnotes-with-back-references/1799 "2023-03-05T04:00:31Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Jason-Abbott](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.citationstyles.org/jason-abbott/32/449_2.png) [@Jason-Abbott](https://discourse.citationstyles.org/u/Jason-Abbott)
#### Post date: [March 5, 2023, 4:00am UTC](https://discourse.citationstyles.org/t/disambiguating-footnotes-with-back-references/1799/1 "2023-03-05T04:00:31Z")

</div>

Hello from the future. It’s 2023 where (when?) I am. Most of the threads I’ve consulted are over ten years old. I hope some contributors are still around.

I am finishing up a CSL processor written in Swift. It was passing all the disambiguation tests (including Andrea\*.txt) until I ran into bugreports\_EnvAndUrb.txt.

The difficulty is that it has a position=subsequent condition in the citation element to render citations after the first _differently_.

At the same time, I had earlier noticed while coding that @Frank_Bennett [said](https://discourse.citationstyles.org/t/how-do-you-disambiguate-that/851/8) of a different test, “ITEM-1 should render in the same form everywhere in the document.”

I took that to mean (and that test seems to confirm) that whatever is done to disambiguate a cite in one place should apply to the same cite elsewhere.

It is obvious that this can’t apply to an “ibid” or similar but what is the _rule_?

Does the position condition mean that a given cite may actually appear differently every time? If so, how does that square with “ITEM-1 should render in the same form everywhere”?

Thanks for considering!

---

<div class="post-metadata">

### Author: ![Jason-Abbott](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.citationstyles.org/jason-abbott/32/449_2.png) [@Jason-Abbott](https://discourse.citationstyles.org/u/Jason-Abbott)
#### Post date: [March 6, 2023, 4:56pm UTC](https://discourse.citationstyles.org/t/disambiguating-footnotes-with-back-references/1799/2 "2023-03-06T16:56:53Z")

</div>

I think the “rule” I’ll implement, to see if it makes the remaining tests pass, is to treat cites as render-same-everywhere if their basic render (not yet disambiguated or collapsed) is the same and, of course, they cite the same reference.

So if **ITEM-1** ’s basic render is the same in footnote 5 and 8 but different in 12 and 19 then disambig/collapse updates to **ITEM-1** in footnote 5 will also update its render in footnote 8 but not 12 or 19.

… refactor 14, underway 😄

---

<div class="post-metadata">

### Author: ![Sebastian\_Karcher](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.citationstyles.org/sebastian_karcher/32/176_2.png) [@Sebastian\_Karcher](https://discourse.citationstyles.org/u/Sebastian_Karcher)
#### Post date: [March 6, 2023, 5:20pm UTC](https://discourse.citationstyles.org/t/disambiguating-footnotes-with-back-references/1799/3 "2023-03-06T17:20:07Z")

</div>

Sorry for the late response, but yes, I think that’s right. Frank’s note about ITEM-1 wasn’t a general rule for all styles (which, obviously, doesn’t make sense) but specific to that disambiguation example in a style without any position testing.

(These forums aren’t super active, but people are very much around, yes.)

---

<div class="post-metadata">

### Author: ![Jason-Abbott](https://yyz1.discourse-cdn.com/flex029/user_avatar/discourse.citationstyles.org/jason-abbott/32/449_2.png) [@Jason-Abbott](https://discourse.citationstyles.org/u/Jason-Abbott)
#### Post date: [March 11, 2023, 6:19pm UTC](https://discourse.citationstyles.org/t/disambiguating-footnotes-with-back-references/1799/4 "2023-03-11T18:19:31Z")

</div>

Just to close this out … I updated code so it only “links” (leaves them instances of or pointers to same object) cites as described above — if they render the same before disambiguation and collapsing then they will do so afterwards — and it’s passing the tests.

(I haven’t passed every test in the suite yet but making progress)
