So in anchor we can enforce that a provided account is the system program, the token program, or the associated token program using the following constraint.
my_program: Program<'info, System>
As far as I understand, the check here is just using the program id. Is there a way we can more generically check if a provided account is a program?