On Thursday 23 August 2007 14:29:19 Michael Gogins wrote: > Another idea is to be able to substitute names in the opcode dispatch > table. In other words, if my mother made a piece in 1988 using oldopcodeX > which has now been more accurately implemented using newopcodeX, then I can > say 'replace newopcodeX with oldopcodeX' and my mother's piece can now be > re-rendered using the original oldopcodeX -- without having to change her > orchestra code. > > I think this would be easier to implement than Matt's suggestion, and more > flexible. > > It could be done on the command line like this: > > --replace-opcode newopcode=oldopcode > > Or in the orchestra header like this: > > replace oldopcode=newopcode > > This only makes sense if the signature of newopcodeX is functionally > identical to the signature of oldopcodeX, but of course it would be, or > there is no issue of compatibility. > > This scheme might require adding optional or default arguments to some > opcodes, and it could mean renaming some opcodes, i.e. renaming the current > cpsoct to cpsoctTable or something. But the scheme would work not only with > built-in opcodes, but also with plugin opcodes. > > Does this work? What sounds weird to me is why would csound be doing that job, when a simple search & replace (which all reasonable editors provide) would do. Why complicate csound? I'm pretty sure that a release notes document explaining the new behaviour of the opcodes and where to find the old ones would be enough. Plus, it is kind of weird to have an orchestra where the rendered opcode is not the one written there. -- Felipe Sateler