Opened 3 years ago

Closed 2 years ago

#6064 closed change (fixed)

Put C++ code into a configurable namespace

Reported by: sergz Assignee: sergz
Priority: Unknown Milestone:
Module: Core Keywords:
Cc: hfiguiere Blocked By:
Blocking: Platform: Unknown / Cross platform
Ready: no Confidential: no
Tester: Unknown Verified working: no
Review URL(s):



In order to avoid conflicts with already existing C++ code when one tries to use it natively we should put all our C++ code into a namespace. However it still can make sense to not use a namespace when it's compiled to JS in order to avoid additional dealing with name mangling.

What to change

  • introduce base.h which should be included as the first our header in every our header.
  • introduce ABP_USER_CONFIG which is a path to a header file included by base.h and representing options which may be configured by a user. If it's not defined then use user.h.
  • add defines ABP_NS, ABP_NS_BEGIN, ABP_NS_END and ABP_NS_USING into user.h and add corresponding usage of them into all headers and C++ files.

Change History (4)

comment:1 Changed 3 years ago by sergz

  • Review URL(s) modified (diff)
  • Status changed from new to reviewing

comment:2 Changed 3 years ago by fhd

  • Cc trev removed

comment:3 Changed 2 years ago by abpbot

A commit referencing this issue has landed:
Issue 6064 - Put C++ code into a configurable namespace

comment:4 Changed 2 years ago by sergz

  • Resolution set to fixed
  • Status changed from reviewing to closed
Note: See TracTickets for help on using tickets.