[Freeciv-tickets] [freeciv] #44084: changed all ocurrences of action_list to action_group and act_list to act_group

Back to archive index
OSDN Ticket System norep****@osdn*****
Sun Mar 13 01:19:04 JST 2022


#44084: changed all ocurrences of action_list to action_group and act_list to act_group

  Open Date: 2022-03-12 11:25
Last Update: 2022-03-12 13:19

URL for this Ticket:
    https://osdn.net//projects/freeciv/ticket/44084
RSS feed for this Ticket:
    https://osdn.net/ticket/ticket_rss.php?group_id=12505&tid=44084

---------------------------------------------------------------------

Last Changes/Comment on this Ticket:
2022-03-12 13:19 Updated by: dark-ether

Comment:

Reply To cazfi
Reply To dark-ether
however action_list_iterate is being used

I've not looked the patch yet, but aren't those (or at least some of them) iterations supposed to happen over all actions, custom or not. So all actions should be in the same list, no separate constructs for custom and internal actions (as much as there is "internal" actions in the long term plans - I don't know how much they are supposed to get generalized away).
i am not certain but i think no, there is a action_iterate function which seems to be for all actions iteration, and in the code i looked at using action_list_iterate it seems to iterate over a array of stored actions id so it probably is  iteration over a subgroup of all actions. but even then i haven't changed much, just renamed all action_list and act_list ocurrences to action_group and act_group if i haven't missed anything, it should continue working just as before.

---------------------------------------------------------------------
Ticket Status:

      Reporter: dark-ether
         Owner: (None)
          Type: Patches
        Status: Open
      Priority: 5 - Medium
     MileStone: (None)
     Component: General
      Severity: 5 - Medium
    Resolution: None
---------------------------------------------------------------------

Ticket details:

for adding custom actions it will be necessary to store information about the actions, the method i thought about would be creating a speclist for action structs and changing the structs to store all necessary information about the actions.
however action_list_iterate is being used, so it is necessary to change it. also having various lists function that aren't related to the lists would be confusing so i changed every ocurrence for the currently existing functions from list to group.i used ripgrep to find all files with either action_list or act_list and then on each of these files used sed to change action_list to action_group and act_list to act_group.i then used git diff to find all the differences and if it looked if it shouldn't be changed i reverted the change. example: the ChangeLog File
i also added a rule_name field to the action struct.

-- 
Ticket information of Freeciv project
Freeciv Project is hosted on OSDN

Project URL: https://osdn.net/projects/freeciv/
OSDN: https://osdn.net

URL for this Ticket:
    https://osdn.net/projects/freeciv/ticket/44084
RSS feed for this Ticket:
    https://osdn.net/ticket/ticket_rss.php?group_id=12505&tid=44084



More information about the Freeciv-tickets mailing list
Back to archive index