FairRootGroup / FairRoot

C++ simulation, reconstruction and analysis framework for particle physics experiments
http://fairroot.gsi.de
Other
57 stars 96 forks source link

Tutorial4 plots.C: errors in macro #1209

Closed pbelecky closed 2 months ago

pbelecky commented 2 years ago

FairRoot version: v18.6.4

Errors while running examples/simulation/Tutorial4/macros/plots.C:

$ cd examples/simulation/Tutorial4/macros
$ root plots.C
/simulation/Tutorial4/macros/plots.C:8:1: error: C++ requires a type specifier for all declarations
plots(Int_t nEvents = 1000, Int_t iout = 1, TString mcEngine = "TGeant3")
...

When I add void in front of plots() function declaration then following errors get when run macro:

$ root plots.C
...
simulation/Tutorial4/macros/plots.C:22:11: error: no member named 'AddFriend' in 'FairRunAna'
    fRun->AddFriend(RecoFile.Data());
...
ChristianTackeGSI commented 2 years ago

Hi @pavel532,

1212 has been merged and should fix this. Can you take a look?

karabowi commented 2 months ago

Problem has been fixed.